Skip to content

Conversation

@liuruyan
Copy link
Contributor

@liuruyan liuruyan commented Dec 30, 2025

PR Category

Operator Mechanism

PR Types

New features

Description

为fp8_quant_blockwise升级支持ue8m0类型scale

@paddle-bot
Copy link

paddle-bot bot commented Dec 30, 2025

你的PR提交成功,感谢你对开源项目的贡献!
请关注后续CI自动化测试结果,详情请参考Paddle-CI手册
Your PR has been submitted. Thanks for your contribution!
Please wait for the result of CI firstly. See Paddle CI Manual for details.

@codecov-commenter
Copy link

codecov-commenter commented Jan 5, 2026

Codecov Report

❌ Patch coverage is 0% with 19 lines in your changes missing coverage. Please review.
⚠️ Please upload report for BASE (develop@a977b32). Learn more about missing BASE report.

Files with missing lines Patch % Lines
paddle/phi/infermeta/unary.cc 0.00% 19 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             develop   #77153   +/-   ##
==========================================
  Coverage           ?    0.00%           
==========================================
  Files              ?        1           
  Lines              ?       19           
  Branches           ?        0           
==========================================
  Hits               ?        0           
  Misses             ?       19           
  Partials           ?        0           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@liuruyan liuruyan changed the title support quant ue8m0 【Quant】support ue8m0 for fp8_quant_blockwise Jan 6, 2026
zyfncg
zyfncg previously approved these changes Jan 6, 2026
SigureMo
SigureMo previously approved these changes Jan 6, 2026
qingqing01
qingqing01 previously approved these changes Jan 8, 2026
@liuruyan liuruyan dismissed stale reviews from zyfncg, SigureMo, and qingqing01 via 8196010 January 14, 2026 11:32
@liuruyan liuruyan closed this Jan 14, 2026
@liuruyan liuruyan reopened this Jan 14, 2026

- op: fp8_quant_blockwise
args: (Tensor x, float epsilon, bool using_1x128_vec_quant, bool input_transpose, bool output_scale_transpose, bool return_transpose_only, bool using_e5m2, bool using_pow2_scale)
args: (Tensor x, float epsilon, bool using_1x128_vec_quant, bool input_transpose, bool output_scale_transpose, bool return_transpose_only, bool using_e5m2, bool using_pow2_scale, bool using_ue8m0_scale)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

using_pow2_scale 和 using_ue8m0_scale 之间会有影响吗?

Copy link
Contributor Author

@liuruyan liuruyan Jan 15, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

没有影响,using_pow2_scale代表使用2的幂次scale,但是类型仍为float32。using_ue8m0_scale代表不仅仅使用2的幂次scale,并且输出为int32(4个ue8m0)。当两个同时开启时会以using_ue8m0_scale为准。

并且单测中存在笛卡尔积测试样例。两者不会互相冲突

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

作为正式api的话,这些细节需要在api文档里说明,否则使用者只能通过试运行来确定参数作用

Copy link
Contributor Author

@liuruyan liuruyan Jan 15, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

好的,现在是所有attr都没有注释说明,我下一个PR来在python api处为这个算子补充一下完整的注释吧。

@liuruyan liuruyan merged commit 09d88f9 into PaddlePaddle:develop Jan 15, 2026
95 of 102 checks passed
@liuruyan liuruyan mentioned this pull request Jan 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants